import {ajax} from "./util.js";
//获取标题和内容
let title = document.querySelector("#title")
let content = document.querySelector("#content")

let btn = document.querySelector("button")

btn.onclick = function() {
  let data = {
    title:title.value,
    content:content.value
  }

  ajax.post("http://localhost/add", data)
}
// ajax.post("http://localhost/add")